package club.mzywucai.blog.file_system.service;

import club.mzywucai.blog.file_system.pojo.domain.JsonData;
import club.mzywucai.blog.file_system.pojo.po.UserPo;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpSession;

/**
 * @author mzywucai
 * @Description
 * @date 2019/2/9
 */
public interface LoginAndRegisterService {

    /**
     * @Description 单独获得最新的头像地址的方法
     * @author mzywucai
     * @time 2019-02-11
     * @see 
     * @return   club.mzywucai.blog.file_system.pojo.domain.JsonData
     * @params  [session]
     */
    JsonData getPhotoURI(HttpSession session);

    /**
     * @Description 登录
     * @author mzywucai
     * @time 2019-02-11
     * @see 
     * @return   club.mzywucai.blog.file_system.pojo.domain.JsonData
     * @params  [email, password, session]
     */
    JsonData login(String email, String password, HttpSession session);

    /**
     * @Description 注册
     * @author mzywucai
     * @time 2019-02-11
     * @see
     * @return   club.mzywucai.blog.file_system.pojo.domain.JsonData
     * @params  [email, password, request]
     */
    JsonData register(String email, String password, HttpServletRequest request);

    /**
     * @Description 确认存在，获得邮箱
     * @author mzywucai
     * @time 2019-02-09
     * @see 
     * @return   java.lang.String
     * @params  [UUID]
     */
    String activationBefore(String UUID);
    
    /**
     * @Description 用户激活并且加上用户名
     * @author mzywucai
     * @time 2019-02-09
     * @see 
     * @return   void
     * @params  [UUID, username]
     */
    JsonData activation(String UUID, String username);

    /**
     * @Description 修改用户个人的是否全站静默的状态
     * @author mzywucai
     * @time 2019-02-15
     * @see 
     * @return   club.mzywucai.blog.file_system.pojo.domain.JsonData
     * @params  [session, silentStatus]
     */
    JsonData updateUserPersonalSilentStatus(HttpSession session, int silentStatus);
}
